var relatedcollection=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(ds,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+(PersonasWindow.createEncodedName(name))+"backs"));
var collectionsseqenumurator=relatedcollection.GetElements();
var totalpersonasnumber=0;
while (collectionsseqenumurator.hasMoreElements()) {
var cfgretrieverdf = Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile);
document.getElementById("newshtmldiv").getElementsByTagName("image")[i].setAttribute("tooltiptext",retrievedimagename+" - Double click on it to visit web page");
var createdCompositeFileName=decodeURI(document.getElementsByClassName("active")[0].getAttribute("id").replace(/htmldiv$/,""))+"/"+"Personas"+"/"+leafName;
var filename=PersonasWindow.checkNameCollison(createdCompositeFileName);
var filem=PersonasWindow.getAppropriateCollectionDirectoryFromFileName(filename);
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getTheURIFromFileName(PersonasWindow.createIndividualRDFFilename(filename)));
var leafName=PersonasWindow.getTheLeafNameFromFileNameString(filename);
var theImageNode = PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(filename));
var positionPredicate=PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#position");
var positiontarget=ds.GetTarget(theImageNode,positionPredicate,true);
if (positiontarget!=null) var position= positiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
else {return}
var newposition="CENTER";
var predicate=PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#position");
var oldtarget=PersonasRotatorRDF.rdfService.GetLiteral(position);
var newtarget=PersonasRotatorRDF.rdfService.GetLiteral(newposition);
var mainSeq=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(ds,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+PersonasWindow.createEncodedName(decodeURI(document.getElementsByClassName("active")[0].getAttribute("id").replace(/htmldiv$/,"")))+"backs"));
addImageResourceNodeToCollectionDatabase: function (filename) {
var imagename = PersonasWindow.actualfilename.replace(/\.\w+$/,"");
var imagelocation = PersonasWindow.getTheLeafNameFromFileNameString(filename);
var imagedescription = "undefined";
var imageposition = "CENTER";
var activecollectioname=filename.split("/")[0];
var imageversion="0.1";
var imageuploaded="false";
var imagesiteURI="null".replace(/&/g,"&");
var imagesource="local";
var imagescreenRes=screen.width+"x"+screen.height;
var imagebackgroundColor=PersonasWindow.retrieveDesktopBackgroundColor();
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getTheURIFromFileName(PersonasWindow.createCollectionRDfFileName(filename)));
var newnode=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(filename));
var mainSeq=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(ds,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+PersonasWindow.createEncodedName(decodeURI(document.getElementsByClassName("active")[0].getAttribute("id").replace(/htmldiv$/,"")))+"backs"));
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getTheURIFromFileName(PersonasWindow.createCollectionRDfFileName(filename)));
var leafName=PersonasWindow.getTheLeafNameFromFileNameString(filename);
var theImageNode = PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(filename));
var positionPredicate=PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#position");
var positiontarget=ds.GetTarget(theImageNode,positionPredicate,true);
if (positiontarget!=null) var position= positiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
else {return}
var newposition="CENTER";
var predicate=PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#position");
var oldtarget=PersonasRotatorRDF.rdfService.GetLiteral(position);
var newtarget=PersonasRotatorRDF.rdfService.GetLiteral(newposition);
var file=Components.classes["@mozilla.org/file/directory_service;1"].getService(Components.interfaces.nsIProperties).get("ProfD", Components.interfaces.nsIFile);
file.append("personasrotator");
for (var i=0;i<namesplitarray.length;i++) {
file.append(namesplitarray[i]);
}
var ios=Components.classes["@mozilla.org/network/io-service;1"]
var chosenbuttonname=node.getAttribute("id").replace(/button$/,"");
var relatedhtmldiv=document.getElementById(chosenbuttonname+"htmldiv");
var collectionname=decodeURI(chosenbuttonname)
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getlibraryfileURI());
var relatedcollection=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(ds,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+(PersonasWindow.createEncodedName(collectionname))+"backs"));
var collectionsseqenumurator=relatedcollection.GetElements();
var totalpersonasnumber=0;
while (collectionsseqenumurator.hasMoreElements()) {
collectionsseqenumurator.getNext();
totalpersonasnumber++;
}
var confirmtext="Collection will be removed.";
if (totalpersonasnumber>0) {
confirmtext+=" Personas that belongs to this collection will be removed, too.\nWould you like to continue?";
}
else {
confirmtext+="Would you like to continue?";
}
var response=PersonasWindow.createConfirmPrompt(confirmtext);
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getTheURIFromFileName(PersonasWindow.createCollectionRDfFileName(filename)));
var uri=PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(filename);
var rdfnode = PersonasRotatorRDF.rdfService.GetResource(uri);
var activecollectionname=activecollectionnamepassed;
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getlibraryfileURI());
var container=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(ds,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+PersonasWindow.createEncodedName(activecollectionname)+"backs"));
var genericpersonaslienumurator=container.GetElements();
PersonasWindow.personasarray=[];
var inc=0;
while (genericpersonaslienumurator.hasMoreElements()) {
var genericpersonas=genericpersonaslienumurator.getNext();
var imageResource=genericpersonas;
var imagenamePredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#name");
var imagenametarget=ds.GetTarget(imageResource,imagenamePredicate,true);
if (imagenametarget) {
var imagename = imagenametarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagedescriptionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#description");
var imagedescriptiontarget=ds.GetTarget(imageResource,imagedescriptionPredicate,true);
if (imagedescriptiontarget) {
var imagedescription = imagedescriptiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagelocationPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#location");
var imagelocationtarget=ds.GetTarget(imageResource,imagelocationPredicate,true);
if (imagelocationtarget) {
var imagelocation = imagelocationtarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
if (0==PersonaWindowSelectManager.highlighteds.length) return;
PersonasWindow.copypasteprocessingstate=true;
if(origin=="button"){
var collectioname=PersonasWindow.retrieveButtonName(document.popupNode);
}
else {
var collectioname=decodeURI(document.getElementsByClassName("active")[0].getAttribute("id").replace(/htmldiv$/,""));
}
for (var i=0;i<PersonaWindowSelectManager.highlighteds.length;i++) {
var node=PersonaWindowSelectManager.highlighteds[i];
var toBeCopiedThumbfilename=node.getAttribute("filename");
var toBeCopiedPersonaImagefilename=PersonasWindow.createPersonaImageNameFromThumbImageName(toBeCopiedThumbfilename);
var destinationFilenameToSaveTheCopyImage=collectioname+"/"+"Personas"+"/"+PersonasWindow.getTheLeafNameFromFileNameString(toBeCopiedPersonaImagefilename);
var destinationFilenameToSaveTheCopyImage=PersonasWindow.checkNameCollison(destinationFilenameToSaveTheCopyImage);
var destinationThumbImagefileame=collectioname+"/"+"Thumbs/Thumb_"+PersonasWindow.getTheLeafNameFromFileNameString(destinationFilenameToSaveTheCopyImage);
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getlibraryfileURI());
var copynode=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(toBeCopiedPersonaImagefilename));
var imageResource=copynode;
var imagenamePredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#name");
var imagenametarget=ds.GetTarget(imageResource,imagenamePredicate,true);
if (imagenametarget) {
var imagename = imagenametarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagedefaultPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#default");
var imagedefaulttarget=ds.GetTarget(imageResource,imagedefaultPredicate,true);
if (imagedefaulttarget) {
var imagedefault = imagedefaulttarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagelocation = PersonasWindow.getTheLeafNameFromFileNameString(destinationFilenameToSaveTheCopyImage);
var imagedescriptionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#description");
var imagedescriptiontarget=ds.GetTarget(imageResource,imagedescriptionPredicate,true);
if (imagedescriptiontarget) {
var imagedescription = imagedescriptiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagepositionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#position");
var imagepositiontarget=ds.GetTarget(imageResource,imagepositionPredicate,true);
if (imagepositiontarget) {
var imageposition = imagepositiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagetagsPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#tags");
var imagetagstarget=ds.GetTarget(imageResource,imagetagsPredicate,true);
if (imagetagstarget) {
var imagetags = imagetagstarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imageversionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#version");
var imageversiontarget=ds.GetTarget(imageResource,imageversionPredicate,true);
if (imageversiontarget) {
var imageversion = imageversiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imageuploadedPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#uploaded");
var imageuploadedtarget=ds.GetTarget(imageResource,imageuploadedPredicate,true);
if (imageuploadedtarget) {
var imageuploaded = imageuploadedtarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagesiteURIPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#siteuri");
var imagesiteURItarget=ds.GetTarget(imageResource,imagesiteURIPredicate,true);
if (imagesiteURItarget) {
var imagesiteURI = imagesiteURItarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagesourcePredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#source");
var imagesourcetarget=ds.GetTarget(imageResource,imagesourcePredicate,true);
if (imagesourcetarget) {
var imagesource = imagesourcetarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagescreenResPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#screenres");
var imagescreenRestarget=ds.GetTarget(imageResource,imagescreenResPredicate,true);
if (imagescreenRestarget) {
var imagescreenRes = imagescreenRestarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagebackgroundColorPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#backgroundcolor");
var imagebackgroundColortarget=ds.GetTarget(imageResource,imagebackgroundColorPredicate,true);
if (imagebackgroundColortarget) {
var imagebackgroundColor = imagebackgroundColortarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var newnode=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(destinationFilenameToSaveTheCopyImage));
var mainSeq=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(ds,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+PersonasWindow.createEncodedName(collectioname)+"backs"));
var dsx=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getTheURIFromFileName(PersonasWindow.createCollectionRDfFileName(destinationFilenameToSaveTheCopyImage)));
var newnode2=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+destinationFilenameToSaveTheCopyImage);
var mainSeq2=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(dsx,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+PersonasWindow.createEncodedName(collectioname)+"backs"));
var destinationRDFImagefilename=destinationFilenameToSaveTheCopyOrCutImage.split("/")[0]+"/"+"RDFs/"+PersonasWindow.getTheLeafNameFromFileNameString(destinationFilenameToSaveTheCopyOrCutImage)+".rdf";
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getlibraryfileURI());
var copynode=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(toBeCopiedPersonaImagefilename));
var imageResource=copynode;
var imagenamePredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#name");
var imagenametarget=ds.GetTarget(imageResource,imagenamePredicate,true);
if (imagenametarget) {
var imagename = imagenametarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagedefaultPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#default");
var imagedefaulttarget=ds.GetTarget(imageResource,imagedefaultPredicate,true);
if (imagedefaulttarget) {
var imagedefault = imagedefaulttarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagedescriptionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#description");
var imagedescriptiontarget=ds.GetTarget(imageResource,imagedescriptionPredicate,true);
if (imagedescriptiontarget) {
var imagedescription = imagedescriptiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagepositionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#position");
var imagepositiontarget=ds.GetTarget(imageResource,imagepositionPredicate,true);
if (imagepositiontarget) {
var imageposition = imagepositiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagetagsPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#tags");
var imagetagstarget=ds.GetTarget(imageResource,imagetagsPredicate,true);
if (imagetagstarget) {
var imagetags = imagetagstarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imageversionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#version");
var imageversiontarget=ds.GetTarget(imageResource,imageversionPredicate,true);
if (imageversiontarget) {
var imageversion = imageversiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imageuploadedPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#uploaded");
var imageuploadedtarget=ds.GetTarget(imageResource,imageuploadedPredicate,true);
if (imageuploadedtarget) {
var imageuploaded = imageuploadedtarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagesiteURIPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#siteuri");
var imagesiteURItarget=ds.GetTarget(imageResource,imagesiteURIPredicate,true);
if (imagesiteURItarget) {
var imagesiteURI = imagesiteURItarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagesourcePredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#source");
var imagesourcetarget=ds.GetTarget(imageResource,imagesourcePredicate,true);
if (imagesourcetarget) {
var imagesource = imagesourcetarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagescreenResPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#screenres");
var imagescreenRestarget=ds.GetTarget(imageResource,imagescreenResPredicate,true);
if (imagescreenRestarget) {
var imagescreenRes = imagescreenRestarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagebackgroundColorPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#backgroundcolor");
var imagebackgroundColortarget=ds.GetTarget(imageResource,imagebackgroundColorPredicate,true);
if (imagebackgroundColortarget) {
var imagebackgroundColor = imagebackgroundColortarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var nameForImage = imagename.replace(/&/g,"&");
var locationForImage =PersonasWindow.getTheLeafNameFromFileNameString(destinationFilenameToSaveTheCopyOrCutImage).replace(/&/g,"&");
var descriptionForImage = imagedescription.replace(/&/g,"&");
var positionForImage = imageposition.replace(/&/g,"&");
var defaultForImage = imagedefault.replace(/&/g,"&");
var tagsForImage = (copyorcut=="copy") ? PersonasWindow.returnCopyTagString(imagetags,destinationFilenameToSaveTheCopyOrCutImage.split("/")[0]).replace(/&/g,"&") : PersonasWindow.returnCutTagString(imagetags,toBeCopiedPersonaImagefilename.split("/")[0],destinationRDFImagefilename.split("/")[0]).replace(/&/g,"&");
var versionForImage = imageversion.replace(/&/g,"&");
var uploadedForImage = imageuploaded.replace(/&/g,"&");
var siteURIForImage = imagesiteURI.replace(/&/g,"&");
var sourceForImage = imagesource.replace(/&/g,"&");
var screenResForImage = imagescreenRes.replace(/&/g,"&");
var backgroundColorForImage = imagebackgroundColor.replace(/&/g,"&");
var RDFstring='<?xml version="1.0"?>'+'<RDF:RDF xmlns:personasrotator="urn:personasrotator#" xmlns:NC="http://home.netscape.com/NC-rdf#" xmlns:RDF="http://www.w3.org/1999/02/22-rdf-syntax-ns#">'+
if (0==PersonaWindowSelectManager.highlighteds.length) return;
PersonasWindow.cutpasteprocessingstate=true;
if(origin=="button"){
var collectioname=PersonasWindow.retrieveButtonName(document.popupNode);
}
else {
var collectioname=decodeURI(document.getElementsByClassName("active")[0].getAttribute("id").replace(/htmldiv$/,""));
}
for (var i=0;i<PersonaWindowSelectManager.highlighteds.length;i++) {
var node=PersonaWindowSelectManager.highlighteds[i];
var toBeCutThumbfilename=node.getAttribute("filename");
var toBeCutPersonaImagefilename=PersonasWindow.createPersonaImageNameFromThumbImageName(toBeCutThumbfilename);
var destinationFilenameToSaveTheCutImage=collectioname+"/"+"Personas"+"/"+PersonasWindow.getTheLeafNameFromFileNameString(toBeCutPersonaImagefilename);
var destinationFilenameToSaveTheCutImage=PersonasWindow.checkNameCollison(destinationFilenameToSaveTheCutImage);
var destinationThumbImagefileame=collectioname+"/"+"Thumbs/Thumb_"+PersonasWindow.getTheLeafNameFromFileNameString(destinationFilenameToSaveTheCutImage);
var oldRDFnsiFile=PersonasWindow.getChromeFile(PersonasWindow.createIndividualRDFFilename(toBeCutPersonaImagefilename));
oldRDFnsiFile.remove(false);
var ds=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getlibraryfileURI());
var cutnode=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(toBeCutPersonaImagefilename));
var imageResource=cutnode;
var imagenamePredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#name");
var imagenametarget=ds.GetTarget(imageResource,imagenamePredicate,true);
if (imagenametarget) {
var imagename = imagenametarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagedefaultPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#default");
var imagedefaulttarget=ds.GetTarget(imageResource,imagedefaultPredicate,true);
if (imagedefaulttarget) {
var imagedefault = imagedefaulttarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagelocation = PersonasWindow.getTheLeafNameFromFileNameString(destinationFilenameToSaveTheCutImage);
var imagedescriptionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#description");
var imagedescriptiontarget=ds.GetTarget(imageResource,imagedescriptionPredicate,true);
if (imagedescriptiontarget) {
var imagedescription = imagedescriptiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagepositionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#position");
var imagepositiontarget=ds.GetTarget(imageResource,imagepositionPredicate,true);
if (imagepositiontarget) {
var imageposition = imagepositiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagetagsPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#tags");
var imagetagstarget=ds.GetTarget(imageResource,imagetagsPredicate,true);
if (imagetagstarget) {
var imagetags = imagetagstarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imageversionPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#version");
var imageversiontarget=ds.GetTarget(imageResource,imageversionPredicate,true);
if (imageversiontarget) {
var imageversion = imageversiontarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imageuploadedPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#uploaded");
var imageuploadedtarget=ds.GetTarget(imageResource,imageuploadedPredicate,true);
if (imageuploadedtarget) {
var imageuploaded = imageuploadedtarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagesiteURIPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#siteuri");
var imagesiteURItarget=ds.GetTarget(imageResource,imagesiteURIPredicate,true);
if (imagesiteURItarget) {
var imagesiteURI = imagesiteURItarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagesourcePredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#source");
var imagesourcetarget=ds.GetTarget(imageResource,imagesourcePredicate,true);
if (imagesourcetarget) {
var imagesource = imagesourcetarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagescreenResPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#screenres");
var imagescreenRestarget=ds.GetTarget(imageResource,imagescreenResPredicate,true);
if (imagescreenRestarget) {
var imagescreenRes = imagescreenRestarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var imagebackgroundColorPredicate = PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator#backgroundcolor");
var imagebackgroundColortarget=ds.GetTarget(imageResource,imagebackgroundColorPredicate,true);
if (imagebackgroundColortarget) {
var imagebackgroundColor = imagebackgroundColortarget.QueryInterface(Components.interfaces.nsIRDFLiteral).Value;
}
var newnode=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(destinationFilenameToSaveTheCutImage));
var mainSeq=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(ds,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+PersonasWindow.createEncodedName(collectioname)+"backs"));
var dsx=PersonasRotatorRDF.rdfService.GetDataSourceBlocking(PersonasWindow.getTheURIFromFileName(PersonasWindow.createCollectionRDfFileName(destinationFilenameToSaveTheCutImage)));
var newnode2=PersonasRotatorRDF.rdfService.GetResource(PersonasWindow.databaseResourceSiteName+PersonasWindow.createEncodedName(destinationFilenameToSaveTheCutImage));
var mainSeq2=PersonasRotatorRDF.rdfContainerUtils.MakeSeq(dsx,PersonasRotatorRDF.rdfService.GetResource("urn:personasrotator:"+PersonasWindow.createEncodedName(collectioname)+"backs"));
if(PersonaWindowSelectManager.highlighteds.length==0) {PersonasWindow.createAlertPrompt(PersonasWindow.STRINGS.getFormattedString("noSelectedItemWarning",["copy or cut the thumbnail. After that right click on collection button to paste."]));return;};